#include <string.h>
#include <stdlib.h>
#include "argv_parse.h"

bool ARG_PARSER::parse_float_args(
	const char *argv[],
	int &argc,
	const ARG_FLOATLIST *args,
	int num_args
)
{
	int i;

	for ( i = 0; i < num_args; ++i )
	{
		if ( strcmp( argv[ argc], args[ i ].arg_name ) == 0 )
		{
			// Bingo!
			argc++;
			* ( args[ i ].arg_destination ) = atof( argv[ argc ] );
			argc++; 
			return true;
		}
	}
	return false;
}


